Committing
the Queue
If the
default callback function is going to be called during the queue commitment,
the context for it must be initialized using the SetupInitDefaultQueueCallback
PVOID Context; \\variable to store the context
returned
\\initialize the
context
Context = SetupInitDefaultQueueCallback( OwnerWindow
);
In the
example, OwnerWindow is the handle to the window that is to become the
parent window of any dialog boxes that the default callback function generates.
After the
queue is built and the callback function that will process queue notifications
has been initialized, you can call SetupCommitFileQueue
The following
example uses SetupCommitFileQueue to commit the queue using the default
callback routine.
test = SetupCommitFileQueue (
OwnerWindow, //window that will own dialog boxes
//created by the
callback routine
MyQueue, //the queue
to commit
//use the default
callback routine
SetupDefaultQueueCallback
Context //context
information that will be
// used by the callback routine
);
In the
preceding example, MyQueue is the queue to commit, OwnerWindow is
the window that will own any dialog boxes created by the default callback
routine, SetupDefaultQueueCallback specifies that the default callback
function will be used, and Context is a pointer to the structure
returned by the previous call to SetupInitDefaultQueueCallback